package com.chen.mobiletwo.tool;

import com.huaban.analysis.jieba.JiebaSegmenter;
import org.springframework.stereotype.Component;

import java.util.List;

//结巴分词
@Component
public class JieBaTool {
    /**
     * 默认的结巴分词
     * @param content 内容
     * @return List
     */
    public List<String> BaseJieBa(String content){
        JiebaSegmenter jiebaSegmenter=new JiebaSegmenter();//新建结巴对象
        List<String> list=jiebaSegmenter.sentenceProcess(content);//分词
        return list;
    }
}
